// Copyright 2018 The OpenPitrix Authors. All rights reserved.
// Use of this source code is governed by a Apache license
// that can be found in the LICENSE file.

package categorycommon

import (
	"sort"
	"strings"
)

func SortedString(s []string) string {
	sortedCategoryIds := sort.StringSlice(s)
	sortedCategoryIds.Sort()
	return strings.Join(sortedCategoryIds, ",")
}
